﻿<%@ Page Language="C#" MasterPageFile="~/ClientSite.Master" AutoEventWireup="true"
    CodeBehind="GioHang.aspx.cs" Inherits="SES.CMS.GioHang" Title="Trang trí ngoại thất" %>

<%@ Register Src="~/Module/ucSanPhamBanChay.ascx" TagName="ucSanBanChay" TagPrefix="uc5" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <style type="text/css">

    </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div id="main">
        <div class="page_margins">
            <div class="page">
                <div class="subcolumns">
                    <div class="c20l">
                        <div class="subnav float_left">
                            <ul class="checkoutSteps clear" style="z-index: 1000;">
                                <li class="step1"><span><a rel="nofollow" href="#"><font><font>1st. </font><font>Mua
                                    hàng</font></font></a></span></li>
                                <li class="step2 active "><span><a rel="nofollow" href="#"><font><font>2rd. </font><font>
                                    Cung cấp địa chỉ giao hàng </font></font></a></span></li>
                                <li class="step3"><span><font><font>3th </font><font>Chuyển hàng </font></font></span>
                                </li>
                                <li class="step4"><span><font><font>4th </font><font>Kiểm tra </font></font></span>
                                </li>
                                <li class="step5 defaultLast  "><span><font><font>5th </font><font>Xác nhận </font></font>
                                </span></li>
                            </ul>
                        </div>
                        <div class="subnavbottom">
                        </div>
                    </div>
                    <div class="c80r">
                        <div class="shoppingcart">
                            
                            <div class="textbox">
                                <div id="basket" class="basketitems">
                                    <div class="listhead">
                                        <h2 class="borderbottom">
                                            Cart</h2>
                                    </div>
                                    <asp:Label ID="lbl" runat="server"></asp:Label>
                                    <asp:GridView runat="server" ID="GridGioHang" AutoGenerateColumns="False" EmptyDataText="Không có dữ liệu !"
                                        AllowPaging="True" OnPageIndexChanging="GridGioHang_PageIndexChanging" OnRowCommand="GridGioHang_RowCommand"
                                        CellPadding="0" Width="99%" BackColor="White" BorderColor="#CC9966" BorderStyle="None"
                                        BorderWidth="0" DataKeyNames="SanPhamID" OnDataBinding="GridGioHang_DataBinding"
                                        OnDataBound="GridGioHang_DataBound" CssClass="mGrid" PagerStyle-CssClass="pgr"
                                        AlternatingRowStyle-CssClass="alt" RowStyle-CssClass="rgr" HeaderStyle-CssClass="hgr">
                                        <RowStyle />
                                        <Columns>
                                            <asp:TemplateField Visible="false" HeaderText="<%$Resources:Language,rlblSTT %>"
                                                ItemStyle-Width="13px">
                                                <ItemTemplate>
                                                    <asp:Label Visible="false" runat="server" ID="lbSTT" Text="<%# Container.DataItemIndex + 1 %>">
                                                    </asp:Label>
                                                </ItemTemplate>
                                                <ItemStyle HorizontalAlign="Center" />
                                                <FooterTemplate>
                                                    Tổng tiền:
                                                </FooterTemplate>
                                                <FooterStyle BorderColor="White" Font-Bold="true" ForeColor="Red" />
                                            </asp:TemplateField>
                                            <asp:TemplateField  HeaderText='<%$Resources:Language,rlblImage%>' ItemStyle-Width="115px">
                                                <ItemTemplate>
                                                    <a class="fackybox" href='/Media/<%#Eval("HinhAnh")%>'>
                                                        <img src='/Media/<%#Eval("HinhAnh")%>' height="70px" width="90px" />
                                                    </a>
                                                </ItemTemplate>
                                                <ItemStyle HorizontalAlign="Center" />
                                            </asp:TemplateField>
                                            <asp:TemplateField HeaderText='<%$Resources:Language,rlblProductName %>' ItemStyle-Width="180px">
                                                <ItemTemplate>
                                                    <asp:Label runat="server" ID="txtTen" Text='<%#(bool)(Session["lang"].ToString()=="VN")?DataBinder.Eval(Container.DataItem,"TenSanPham"):DataBinder.Eval(Container.DataItem,"ProductName") %>'>
                                                    </asp:Label>
                                                </ItemTemplate>
                                                <ItemStyle HorizontalAlign="Left" />
                                            </asp:TemplateField>
                                            <asp:TemplateField HeaderText='<%$Resources:Language,rlblNumber%>' ItemStyle-Width="50px">
                                                <ItemTemplate>
                                                    <asp:TextBox runat="server" OnTextChanged="Calc" AutoPostBack="true" ID="txtSL" CssClass="input-text-gridview"
                                                        Text='<%#DataBinder.Eval(Container.DataItem,"SoLuong") %>'>
                                                    </asp:TextBox>
                                                </ItemTemplate>
                                                <ItemStyle HorizontalAlign="Center" />
                                                <FooterStyle BorderColor="White" />
                                            </asp:TemplateField>
                                            <asp:TemplateField HeaderText='<%$Resources:Language,rlblPrice%>' ItemStyle-HorizontalAlign="Center"
                                                ItemStyle-Width="90px">
                                                <ItemTemplate>
                                                    <asp:Label runat="server" ID="lbDG" Text='<%#(bool)(Session["lang"].ToString()=="VN")?DataBinder.Eval(Container.DataItem,"DonGia","{0:0,0 VNĐ}"):DataBinder.Eval(Container.DataItem,"Price","{0:0,0 USD}") %>'>
                                                    </asp:Label>
                                                </ItemTemplate>
                                                <FooterStyle BorderColor="White" />
                                            </asp:TemplateField>
                                            <asp:TemplateField HeaderText='<%$Resources:Language,rlblSaleOff%>' ItemStyle-HorizontalAlign="Center"
                                                ItemStyle-Width="70px">
                                                <ItemTemplate>
                                                    <asp:Label runat="server" ID="lbDGG" Text='<%#Eval("GiamGia") +"%" %>'>
                                                    </asp:Label>
                                                </ItemTemplate>
                                                <FooterStyle BorderColor="White" />
                                            </asp:TemplateField>
                                            <asp:TemplateField HeaderText='<%$Resources:Language,rlblToTal%>' ItemStyle-HorizontalAlign="Center"
                                                ItemStyle-Width="110px">
                                                <ItemTemplate>
                                                    <asp:Label runat="server" ID="lbThanhTien" Font-Bold="true" Text='<%#(bool)(Session["lang"].ToString()=="VN")?Eval("ThanhTien","{0:0,0}"):Eval("TotalMoney","{0:0,0}") %>'>
                                                    </asp:Label>
                                                </ItemTemplate>
                                                <FooterTemplate>
                                                    <asp:Label ID="lbTong" runat="server" Font-Bold="true" ForeColor="Red"></asp:Label>
                                                </FooterTemplate>
                                                <FooterStyle HorizontalAlign="Center" BorderColor="White" />
                                            </asp:TemplateField>
                                            <asp:TemplateField HeaderText='<%$Resources:Language,rlblAction%>'>
                                                <ItemTemplate>
                                                    <asp:ImageButton runat="server" ID="img_xoa" CommandName="xoa" OnClientClick="return confirm('Bạn có muốn loại bỏ sản phẩm này ra khỏi giỏ hàng?')"
                                                        CommandArgument='<%#DataBinder.Eval(Container.DataItem,"STT") %>' CssClass="button-gridview" />
                                                </ItemTemplate>
                                                <ItemStyle HorizontalAlign="Center" />
                                                <FooterStyle BorderColor="White" />
                                            </asp:TemplateField>
                                        </Columns>
                                        <FooterStyle BackColor="White" ForeColor="#000066" />
                                        <PagerStyle BackColor="#FFFFCC" ForeColor="#330099" />
                                        <SelectedRowStyle />
                                        <HeaderStyle />
                                    </asp:GridView>
                                    <br />
                                    <div class="dvTotalMoney">
                                        <asp:Label ID="lblSum" runat="server" Font-Size="15px"></asp:Label><br />
                                        <asp:Label ID="lbThanhTien" runat="server" Font-Size="15px"></asp:Label>
                                    </div>
                                </div>
                            </div>
                            <div class="textbox">
                                <div align="center" style="margin-top: 10px;" class="ltr dGioHang">
                                    <a href="/Default.aspx" class="continue_link">
                                        <asp:Label runat="server" ID="rContinue" Text="<%$Resources:Language, rContinue %>"></asp:Label></a>
                                    <asp:LinkButton runat="server" ID="lblThanhToan" CssClass="checkout_link" Text="<%$Resources:Language, lbThanhtoan %>"
                                        OnClick="lblThanhToan_Click"></asp:LinkButton>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</asp:Content>
